home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Celestin Apprentice 5
/
Apprentice-Release5.iso
/
Source Code
/
C
/
Applications
/
Fixation 1.3
/
tcpstuff.h
< prev
next >
Wrap
Text File
|
1996-01-13
|
820b
|
30 lines
// tcpstuff.h
enum {
kMaxStreams = 1,
kBufferLength = 8*1024,
kMinTCPBufSize = 32*1024, /* minimum MacTCP stream buffer size */
kStatClosed = 0,
kStatListening,
kStatOpen,
kStatOther
};
extern unsigned long gMyAddress;
extern unsigned char buf[kMaxStreams][kBufferLength];
extern long bufdata[kMaxStreams];
extern short nexStatus[kMaxStreams];
OSErr NetIdle (void);
OSErr NetInit (void);
void ReleaseStreams(void);
OSErr DoTCPActiveOpen (short stream, unsigned long addr,
unsigned short port);
OSErr DoTCPPassiveOpen (short stream, unsigned short *port);
OSErr NetNameToAddr (char *name,
unsigned long *addr, unsigned short *port);
OSErr NetAddrToName (unsigned long addr, char *name);
OSErr PrepareTheWay(short stream); // De Sade reference . . .
OSErr SendData(short stream, void *data, long length);